﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Profile;
using System.Web.Mvc;
using IPMS.Models;
namespace IPMS.Controllers
{
    public class ProjectController : Controller
    {

        ProjectModel projectModel = new ProjectModel();
        //
        // GET: /Project/
        
        public ActionResult List()
        {
            try
            {
                ProfileBase profile = ProfileBase.Create(User.Identity.Name);
                int userID = Convert.ToInt32(profile["ID"]);
                List<Project> lstProject = this.projectModel.GetListProject(userID);
                return View(lstProject);
            }
            catch(Exception ex)
            {
                return View();
            }
        }

    }
}
